
package com.kweative.network;

import com.kweative.format.UrlFormat;
import com.kweative.type.Node;
import java.io.BufferedReader;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.StringReader;
import java.net.URL;
import java.util.HashMap;

/**
 *
 * @author henrik
 */
public class SocketRequest extends Request {
    @Override
    public void read(InputStream in) throws IOException {
        StringBuilder sb = new StringBuilder();
        BufferedReader br = new BufferedReader(new InputStreamReader(in,"UTF-8"));
        String line;
        while ((line = br.readLine()) != null) {
            sb.append(line).append("\n");
        }
        setBody(sb.toString());
    }
}
